From: Georges Basile Stavracas Neto Date: Wed, 2 Dec 2020 21:35:38 +0000 (-0300) Subject: appDisplay/baseAppView: Use a separate flag for animated indicators X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~616^2^2~706 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=7d4ac04a78358f512e5723841e1f06a752129672;p=gnome-shell.git appDisplay/baseAppView: Use a separate flag for animated indicators In the future, both AppDisplay and FolderView will be horizontal, and thus using the orientation to determine whether to use animated indicators won't be enough. Use a different flag to control that, and make FolderView not use animated page indicators. Part-of: --- diff --git a/js/ui/appDisplay.js b/js/ui/appDisplay.js index a86f32a3b..71aee7bc3 100644 --- a/js/ui/appDisplay.js +++ b/js/ui/appDisplay.js @@ -127,6 +127,11 @@ var BaseAppView = GObject.registerClass({ }, }, class BaseAppView extends St.Widget { _init(params = {}, orientation = Clutter.Orientation.VERTICAL) { + params = Params.parse(params, { animateIndicators: true }, true); + + const animateIndicators = params.animateIndicators; + delete params.animateIndicators; + super._init(params); this._grid = this._createGrid(); @@ -160,7 +165,7 @@ var BaseAppView = GObject.registerClass({ }); // Page Indicators - if (vertical) + if (animateIndicators) this._pageIndicators = new PageIndicators.AnimatedPageIndicators(orientation); else this._pageIndicators = new PageIndicators.PageIndicators(orientation); @@ -1687,6 +1692,7 @@ class FolderView extends BaseAppView { layout_manager: new Clutter.BinLayout(), x_expand: true, y_expand: true, + animateIndicators: false, }, Clutter.Orientation.HORIZONTAL); // If it not expand, the parent doesn't take into account its preferred_width when allocating